import Vue from "vue";

import "normalize.css/normalize.css"; // A modern alternative to CSS resets

import ElementUI from "element-ui";
//elementUI的sass样式--------------------------------------------
import "element-ui/packages/theme-chalk/src/index.scss";
//自定义配置样式--------------------------------------------
import "@/styles/index.scss"; // global css
//滚动条组件注册--------------------------------------------
import "@/components/vuescroll/vuescroll";
//全局组件--------------------------------------------
import "@/components/index";
//全局指令--------------------------------------------
import "@/directive/index";
//过滤器--------------------------------------------
import * as filters from "@/filters/filter";

import App from "./App";
import store from "./store";
import router from "./router";

import "@/icons"; // icon
import "@/permission"; // permission control

Vue.use(ElementUI);

// register global utility filters
Object.keys(filters).forEach(key => {
  Vue.filter(key, filters[key]);
});

import * as echarts from "echarts";
Vue.prototype.$echarts = echarts;

Vue.config.productionTip = false;

new Vue({
  el: "#app",
  router,
  store,
  render: h => h(App)
});
